
{if $split->getTotalPages() < 10}
	{assign var="looppages" value=$split->getTotalPages()}
{else}
	{assign var="looppages" value=10}
{/if}
{if $split->getCurrentPage() < 6}
	{assign var="mod" value="0"}
{elseif ($split->getCurrentPage()-6) < ($split->getTotalPages()-$looppages)}
	{assign var="mod" value=$split->getCurrentPage()-6}
{else}
	{assign var="mod" value=$split->getTotalPages()-$looppages}
{/if}

{if $split->getTotalPages() > 1}
	{strip}
		<p class="paginateresults">
			<strong>{#TEXT_RESULTS_PAGE#}</strong>
			<br />
			{if $split->getCurrentPage() > 1}
				<a id="prevsearchlink" href="{$smarty.const.FILENAME_CATALOG}?{all_params exclude="page"}&amp;page={$split->getCurrentPage()-1}">{#TEXT_BUTTON_PREV#}</a>
				<span>|</span>
			{/if}
			{section name="page" loop="11" start=1}
				{assign var="index" value=$smarty.section.page.index+$mod}
				{if $index <= $split->getTotalPages()}
					{if !$smarty.section.page.first}<span>|</span>{/if}
					{if $split->isCurrentPage($index)}
						{$index}
					{else}
						<a href="{$smarty.const.FILENAME_CATALOG}?{all_params exclude="page"}&amp;page={$index}">{$index}</a>
					{/if}
				{/if}
			{/section}
			{if $split->getCurrentPage() < $split->getTotalPages()}
				<span>|</span>
				<a id="nextsearchlink" href="{$smarty.const.FILENAME_CATALOG}?{all_params exclude="page"}&amp;page={$split->getCurrentPage()+1}">{#TEXT_BUTTON_NEXT#}</a>
			{/if}
		</p>
	{/strip}
{/if}

